import type { FieldRule } from "vant"

// 手机号表单验证规则
export const mobileRules:FieldRule[] = [
  { required: true, message: '请输入手机号', trigger: 'onChange' },
  { pattern: /^1[3-9]\d{9}$/, message: '请输入正确的手机号',trigger: 'onChange' },
]
export const passwordRules: FieldRule[] = [
  { required: true, message: '请输入密码', trigger: 'onChange' },
  { pattern: /^[0-9A-Za-z]{6,20}$/, message: '6 - 20位密码,数字或字母,区分大小写', trigger: 'onChange' },
]
